<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="language" content="ru" />
<title>Отчет о наличии материалов на складе</title>
<STYLE type="text/css">
body {
	font: 10pt Tahoma,Arial,Helvetica,sans-serif; 
	color: #222222
}
table td {
	vertical-align:baseline;
}
.invship-row {
	overflow-x: hidden;
	width:180mm;
	margin-top: 4pt;
}

/* Typecal usage: <div class="invship-label"><div style="width:30mm;">Поставщик</div></div> */
.invship-label {
	display: inline-block;
	font-weight:700;
	padding-right: 1mm;
}
/* Typecal usage: <div class="invship-data"><div style="min-width:30mm;">Дата</div></div> */
.invship-data {
	display: inline-block;
	border-bottom: 1px solid #222222;
	white-space:normal;
}
.invship-prs-table {
	font-size:8pt;
	white-space:normal;
	margin-top:16pt;
	width: 180mm;
	border: 1px solid #222222;
	border-collapse: collapse;
}
.invship-prs-table td{
	padding: 1mm;
	border: 1px solid #222222;
}

.invship-prs-amount {
	text-align:right;
	padding-left: 5mm;
	white-space:nowrap;
}
.invship-prs-metric {
	text-align:left;
	white-space:nowrap;
}
.invship-title {
	font-weight:700;
	text-align:center;
	background-color:#dddddd;
}
.manplan-opt-amount {
	text-align:left;
	white-space:nowrap;
}
.manplan-pcs {
	text-align:left;
	white-space:nowrap;
}
.manplan-opt-metric {
	text-align:left;
	white-space:nowrap;
}
</STYLE>

</head>

<body>
	<div style="display:inline-block;margin:0 0 5mm 50mm;">
	<center>
	<h3>Накладна</h3>
	На відгрузку № {$data->inv_num} від {$data->inv_date}
	</center>
	</div>
	<div class="invship-row">
		<div class="invship-label"><div style="width:30mm;">Постачальник:</div></div>
		<div class="invship-data"><div style="width:120mm;">{$data->from}</div></div>
	</div>
	<div class="invship-row">
		<div class="invship-label"><div style="width:30mm;">Одержувач:</div></div>
		<div class="invship-data"><div style="width:120mm;">{$data->rcpt}</div></div>
	</div>
<!--
	<div class="invship-row">
		<div class="invship-label"><div style="width:30mm;">На сайт №:</div></div>
		<div class="invship-data"><div style="width:120mm;">
			{if $data->tdate ne ""}{$data->tdate}{else}&nbsp;{/if}
		</div></div>
	</div>
-->
	<div class="invship-row">
		<div class="invship-label"><div style="width:30mm;">За дорученням</div></div>
		<div class="invship-data"><div style="width:120mm;">
			{if $data->tnum ne ""}№ {$data->tnum} {else}&nbsp;{/if}
			{if $data->tdate ne ""} від {$data->tdate}{else}&nbsp;{/if}
		</div></div>
	</div>
	<table class="invship-prs-table">
		<tr>
			<td class="invship-title">№ п/п</td>
			<td class="invship-title">Код</td>
			<td class="invship-title">Найменування</td>
			<td class="invship-title">Кількість</td>
			<td class="invship-title">Одиниці</td>
			<td class="invship-title">Примітка</td>
		</tr>
	{foreach $data->prs as $entry}
		<tr>
			<td>{$entry@index + 1}</td>
			<td>{$entry->art_code}</td>
			<td>{$entry->art_name}</td>
			<td class="invship-prs-amount">{$entry->prs_need|string_format:"%.2f"}</td>
			<td class="invship-prs-metric">{$entry->met_name}</td>
			<td>{$entry->prs_comment}</td>
		</tr>
	{/foreach}
	</table>	
	<table style="width:180mm;margin-top:20pt;"><tr>
		<td>
			<div class="invship-label">Видав: </div>
			<div class="invship-data"><div style="width:25mm;">&nbsp;</div></div>
			{if $data->fpers ne ""}
				<div class="invship-data">/{$data->fpers}/</div>
			{else}
				<div class="invship-data"><div style="width:25mm;">&nbsp;</div></div>
			{/if}
		</td>
		<td style="text-align:right;">
			<div class="invship-label">Одержав: </div>
			<div class="invship-data"><div style="width:25mm;">&nbsp;</div></div>
			{if $data->rpers ne ""}
				<div class="invship-data">/{$data->rpers}/</div>
			{else}
				<div class="invship-data"><div style="width:25mm;">&nbsp;</div></div>
			{/if}
		</td>
	</tr></table>
</body>
</html>
